/*
 * test_system.cpp
 *
 *  Created on: May 19, 2014
 *      Author: killerg
 */


//#include <stdlib.h>
#include "share/util.h"
#include <stdio.h>
#include <assert.h>
#include <string>
using namespace std;

bool test_system() {
	string str = execute("./server -s");
	printf(str.c_str());

	char str1[100];
	char str2[100];
	int pid;
	int shut;
	if (4 == sscanf(str.c_str(), "%s %d %d %s", &str1, &pid, &shut, &str2)) {
		printf("Status:%s\n", str1);
		printf("Stamp:%s\n", str2);
		printf("Pid:%d\n", pid);
		printf("Shut:%d\n", shut);
	}

	return true;
}
